# $Id: PKGBUILD 81045 2012-12-11 02:47:01Z kkeen $
# Maintainer: Kyle Keen <keenerd@gmail.com>
pkgname=zeromq
pkgver=3.2.2
pkgrel=2
pkgdesc="Fast messaging system built on sockets, C and C++ bindings.  aka 0MQ, ZMQ."
arch=('i686' 'x86_64')
url="http://www.zeromq.org"
license=('LGPL')
depends=('gcc-libs' 'util-linux')
makedepends=('python2')
source=(http://download.zeromq.org/$pkgname-$pkgver.tar.gz
        https://raw.github.com/zeromq/cppzmq/master/zmq.hpp)
md5sums=('df68431d9300da84a1a5f9a2784e33de'
         '80b674e98fcc4b4f23ef8b08ce4b051d')

build() {
  cd "$srcdir/$pkgname-$pkgver"
  ./configure prefix=/usr --with-pgm
  sed -i 's/python$/&2/' foreign/openpgm/build-staging/openpgm/pgm/{Makefile,version_generator.py}
  make
}

package() {
  cd "$srcdir/$pkgname-$pkgver"
  make DESTDIR="$pkgdir" install
  install -Dm644 "$srcdir/zmq.hpp" "$pkgdir/usr/include/zmq.hpp"
}


